﻿@model WebUI.Areas.Reports.Models.SpanViewModel
@{
    AjaxOptions ajaxOpts = new AjaxOptions
{
    UpdateTargetId = "RecordsGrid",
    InsertionMode = InsertionMode.Replace,
    LoadingElementId = "divLoading",
    OnSuccess = "initalizetooltip" //because html of grid is replaced, the attached events are gone, we have to reattach them with every post
};
}
@using (Ajax.BeginForm(MVC.Reports.Reports.DeletionCompliancePost(), ajaxOpts))
{
    @Html.ValidationSummary(false)
    <span>Find in previous </span>
    @Html.TextBoxFor(m => m.Value)
    @Html.ValidationMessageFor(model => model.Value)
    @Html.DropDownListFor(m => m.Span, Model.Spans)
    Html.RenderPartial(MVC.Reports.Shared.Views._Columns, Model.filesModel.Columns.Keys);
    <input type="submit"  value='@WebUI.Resources.Search' />
}
@section Title{@Model.filesModel.Title}
@section PageName{@Model.filesModel.Title}
@section Buttons{
    <a href="#">
        <img alt="" src="@Links.Content.images.icon_info_png"
                            width="14" height="14" hspace="7" vspace="2" border="0" align="right" /></a><a href="#"><img
                                alt="" src="@Links.Content.images.icon_print_png" width="16" height="16" hspace="4"
                                border="0" align="right" /></a>}
<div id="divLoading" style="display: none; position: absolute; left: 50%; top: 50%;
    margin-left: -100px; margin-top: -100px">
    <img alt="" src="@Links.Content.images.loading_gif" />
</div>
<div id="RecordsGrid">
    @{ Html.RenderPartial(MVC.Reports.Reports.Views._Records, Model.filesModel); }
</div>
